package cn.com.demo.shiro.dao;

import cn.com.demo.shiro.entity.TShiroUserPermission;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Set;

@Repository
public interface TShiroUserPermissionDao extends BaseMapper<TShiroUserPermission> {

    @Select("SELECT permission_code FROM t_shiro_user_permission WHERE user_id = #{userId} ")
    Set<String> selectPermission(Integer userId);
}